home *** CD-ROM | disk | FTP | other *** search
- /* Example04.plot - Illustration of logarithmic axes, and redefinition
- * - of window
- * Modified for RexxPlPlot by Glenn M. Lewis - 9/12/89
- */
-
- address 'PlPlot'
- say 'Please be patient...'
-
- 'plstar(1,1);'
- 'pladv(0);'
- 'plfont(2);'
-
- f0 = 1000.0;
- do i=1 to 101
- freql.i = i/20.0;
- freq = pow(10.0,freql.i);
- ampl.i = 20.0*log10(1.0/sqrt(1.0+pow((freq/f0),2.0)));
- phase.i = -(180.0/3.141592654)*atan(freq/f0);
- end i
-
- 'plvpor(0.15,0.85,0.1,0.9);'
- 'plwind(1.0,6.0,-80.0,0.0);'
- 'plbox("bclnst",0.0,0,"bnstv",0.0,0);'
- 'plline(101,freql,ampl);'
- 'plptex(5.0,-30.0,1.0,-20.0,0.5,"-20 dB/decade");'
- 'plwind(1.0,6.0,-100.0,0.0);'
- 'plbox(" ",0.0,0,"cmstv",30.0,3);'
- 'plline(101,freql,phase);'
-
- 'plmtex("b",3.2,0.5,0.5,"Frequency");'
- 'plmtex("t",2.0,0.5,0.5,"Single Pole Low-Pass Filter");'
- 'plmtex("l",5.0,0.5,0.5,"Amplitude (dB)");'
- 'plmtex("r",5.0,0.5,0.5,"Phase shift (degrees)");'
-
- 'plend();'
-
- exit 0
-